package com.simple.piger.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.simple.piger.enums.CmsSellerLevel;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * CMS【系统模块】销售管理表
 * @Author  donghj
 * @Date    2017/11/20 20:18
 */
@Data
@TableName("cms_sys_seller")
public class CmsSysSeller extends Model<CmsSysSeller> {
	/**
	 * 主键
	 */
	@TableId(type = IdType.INPUT)
	private String id;
	/**
	 * 用户ID
	 */
	@TableField("user_id")
	private String userId;
	/**
	 * 岗位职级
	 */
	private CmsSellerLevel level;
	/**
	 * 所属上级用户ID
	 */
	@TableField("parent_user_id")
	private String parentUserId;
	/**
	 * 创建时间
	 */
	@TableField("create_date")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	private Date createDate;

	@Override
	protected Serializable pkVal() {
		return this.id;
	}
}